package com.chaodows.commons.exception;

import java.io.Serializable;

/**
 * ============================
 *
 * @Author pengzhichao
 * @Description //TUDO $
 * @Date 2021/7/26 18:52
 * @Version 1.0
 * ============================
 **/
public class MessageException implements Serializable {

    private static final long serialVersionUID = -3215601698894373443L;

    private String title;

    private String message;

    private MessageException(String title, String message) {
        super();
        this.title = title;
        this.message = message;
    }

    public static MessageException getInstance(String title, String message) {
        return new MessageException(title, message);
    }

    public static MessageException getInstance(String message) {
        return new MessageException("error", message);
    }
}
